vim ~/.bashrc


# proxy
proxy () {
  export http_proxy="http://172.27.64.1:7890"
  export https_proxy=$http_proxy
  export socks5_proxy="socks5://172.27.64.1:7890"
  echo "HTTP Proxy on"
}

# noproxy
noproxy () {
  unset http_proxy
  unset https_proxy
  unset socks5_proxy
  echo "HTTP Proxy off"
}

source ~/.bashrc